package net.didactylos.helpline.stripes.security;


/**
 * Built-in security capabilities.
 * 
 * @author david
 */
public enum Capabilities
{
	NONE             (0x0000000000000000L),
	ALL              (0x7FFFFFFFFFFFFFFFL),
	
	SIGN_IN          (0x0000000000000001L),
	
	LOG_PHONECALL    (0x0000000000000002L),
	REPLY_EMAILS     (0x0000000000000004L),
	APPROVE_EMAILS   (0x0000000000000008L),
	
	VIEW_OPTIONS     (0x0000000000000010L),
	MANAGE_OPTIONS   (0x0000000000000030L),

	VIEW_ROLES       (0x0000000000000040L),
	MANAGE_ROLES     (0x00000000000000C0L),
	
	MANAGE_USERS     (0x0000000000000F00L),
	VIEW_USERS       (0x0000000000000100L),
	EDIT_USERS       (0x0000000000000300L),
	CREATE_USERS     (0x0000000000000500L),
	DELETE_USERS     (0x0000000000000900L),
	
	MANAGE_TEMPLATES (0x000000000000F000L),
	VIEW_TEMPLATES   (0x0000000000001000L),
	EDIT_TEMPLATES   (0x0000000000003000L),
	CREATE_TEMPLATES (0x0000000000005000L),
	DELETE_TEMPLATES (0x0000000000009000L),
	
	MANAGE_WIKIPAGES (0x00000000000F0000L),
	VIEW_WIKIPAGES   (0x0000000000010000L),
	EDIT_WIKIPAGES   (0x0000000000030000L),
	CREATE_WIKIPAGES (0x0000000000050000L),
	DELETE_WIKIPAGES (0x0000000000090000L),
	
	MANAGE_REPORTS   (0x0000000000F00000L),
	VIEW_REPORTS     (0x0000000000100000L),
	EDIT_REPORTS     (0x0000000000300000L),
	CREATE_REPORTS   (0x0000000000500000L),
	DELETE_REPORTS   (0x0000000000900000L),
	
	MANAGE_QUEUES    (0x000000000F000000L),
	VIEW_QUEUES      (0x0000000001000000L),
	EDIT_QUEUES      (0x0000000003000000L),
	CREATE_QUEUES    (0x0000000005000000L),
	DELETE_QUEUES    (0x0000000009000000L);

	private long capabilities;
	
	Capabilities(long capabilities)
	{
		this.capabilities = capabilities;
	}

	public long capabilities()
	{
		return capabilities;
	}
	

	
	
	//VIEW_EMAILS      = 0x0000000000000000L;
	
	// Spam
	// Reassign
	// Contact metadata
	// Search
	// Archive
	// Maintenance mode
	
	

}
